<template>
  <div>
    <h3>后台管理</h3>
    <hr />
    <menus />

    <!-- 嵌套路由，则一定要在父路由中添加对应的 挂载点 -->
    <router-view />
  </div>
</template>

<script>
import menu from './ui/menu.vue'
export default {
  components: {
    menus: menu
  },
  created() {
    if (!localStorage.getItem('token')) {
      this.$router.replace('/login')
    }
  }
}
</script>

<style lang="scss" scoped></style>
